mprintf( (0, "This mine has %d unique textures in it (~%d KB)\n", count, (count*4096) /1024 ));
}
mprintf( (0, "Translate=%d\n", translate ));
hashtable_free( &ht );
}
//====================== READ VERTEX INFO ==========================
// New check added to make sure we don't read in too many vertices.
if ( mine_fileinfo.vertex_howmany > MAX_VERTICES )
{
mprintf((0, "Num vertices exceeds maximum. Loading MAX %d vertices\n", MAX_VERTICES));
mine_fileinfo.vertex_howmany = MAX_VERTICES;
}
if ( (mine_fileinfo.vertex_offset > -1) && (mine_fileinfo.vertex_howmany > 0))
{
if (cfseek( LoadFile, mine_fileinfo.vertex_offset, SEEK_SET ))
Error( "Error seeking to vertex_offset in gamemine.c" );
for (i=0; i< mine_fileinfo.vertex_howmany; i++ )
{
// Set the default values for this vertex
Vertices[i].x = 1;
Vertices[i].y = 1;
Vertices[i].z = 1;
if (cfread( &Vertices[i], mine_fileinfo.vertex_sizeof, 1, LoadFile )!=1)
Error( "Error reading Vertices[i] in gamemine.c" );
}
}
//==================== READ SEGMENT INFO ===========================
// New check added to make sure we don't read in too many segments.
if ( mine_fileinfo.segment_howmany > MAX_SEGMENTS ) {
mprintf((0, "Num segments exceeds maximum. Loading MAX %d segments\n", MAX_SEGMENTS));
mine_fileinfo.segment_howmany = MAX_SEGMENTS;
}
// [commented out by mk on 11/20/94 (weren't we supposed to hit final in October?) because it looks redundant. I think I'll test it now...] fuelcen_reset();
if ( (mine_fileinfo.segment_offset > -1) && (mine_fileinfo.segment_howmany > 0)) {
if (cfseek( LoadFile, mine_fileinfo.segment_offset,SEEK_SET ))
Error( "Error seeking to segment_offset in gamemine.c" );